<!--
*Author：jxx
 *Contact：283591387@qq.com
 *代码由框架生成,任何更改都可能导致被代码生成器覆盖
 *业务请在@/extension/system/workbusiness/EQU_COM_DEFINITION_TASK_RECORD.js此处编写
 -->
<template>
    <view-grid ref="grid"
               :columns="columns"
               :detail="detail"
               :editFormFields="editFormFields"
               :editFormOptions="editFormOptions"
               :searchFormFields="searchFormFields"
               :searchFormOptions="searchFormOptions"
               :table="table"
               :extend="extend">
    </view-grid>
</template>
<script>
    import extend from "@/extension/system/workbusiness/EQU_COM_DEFINITION_TASK_RECORD.js";
    import { ref, defineComponent } from "vue";
    export default defineComponent({
        setup() {
            const table = ref({
                key: 'ComDefintion_Task_RecordId',
                footer: "Foots",
                cnName: '数据查询',
                name: 'workbusiness/EQU_COM_DEFINITION_TASK_RECORD',
                url: "/EQU_COM_DEFINITION_TASK_RECORD/",
                sortName: "CreateOn"
            });
            const editFormFields = ref({"Command":"","Equipment_Id":""});
            const editFormOptions = ref([[{"title":"指令","field":"Command","type":"text"},
                               {"dataKey":"设备","data":[],"title":"设备","field":"Equipment_Id","type":"select"}]]);
            const searchFormFields = ref({"OrderCode":"","Equipment_Id":"","CNC_NUM":""});
            const searchFormOptions = ref([[{"dataKey":"工单（没有Id）","data":[],"title":"工单","field":"OrderCode","type":"select"},{"dataKey":"设备","data":[],"title":"设备","field":"Equipment_Id","type":"select"},{"title":"设备No.","field":"CNC_NUM","type":"text"}]]);
            const columns = ref([{field:'ComDefintion_Task_RecordId',title:'ComDefintion_Task_RecordId',type:'guid',width:110,hidden:true,readonly:true,require:true,align:'left'},
                       {field:'OrderCode',title:'工单',type:'string',bind:{ key:'工单（没有Id）',data:[]},width:120,align:'left',sort:true},
                       {field:'ComDefintion_TaskId',title:'ComDefintion_TaskId',type:'string',width:110,hidden:true,align:'left'},
                       {field:'ComDefintionTaskNameZH',title:'指令任务名',type:'string',width:110,hidden:true,align:'left'},
                       {field:'MovePath_Id',title:'路径',type:'string',width:110,hidden:true,align:'left'},
                       {field:'MovePathSub_Id',title:'路径点',type:'string',width:110,hidden:true,align:'left'},
                       {field:'Command',title:'指令',type:'string',width:110,hidden:true,align:'left'},
                       {field:'Equipment_Id',title:'设备',type:'string',bind:{ key:'设备',data:[]},width:110,align:'left'},
                       {field:'Source',title:'来源',type:'string',width:110,hidden:true,align:'left'},
                       {field:'IpUrl',title:'Ip',type:'string',width:110,hidden:true,align:'left'},
                       {field:'ExecuteStart',title:'执行开始时间',type:'datetime',width:150,hidden:true,align:'left',sort:true},
                       {field:'ExecuteEnd',title:'执行结束时间',type:'datetime',width:150,hidden:true,align:'left',sort:true},
                       {field:'SubPathNo',title:'路径序号',type:'int',width:110,hidden:true,align:'left'},
                       {field:'TaskType',title:'任务类型',type:'string',width:110,hidden:true,align:'left'},
                       {field:'Description',title:'重量',type:'string',width:100,align:'left'},
                       {field:'Status',title:'新建/激活/保留/废除',type:'string',width:110,hidden:true,align:'left'},
                       {field:'CreateBy',title:'创建人',type:'string',width:110,hidden:true,align:'left'},
                       {field:'CreateOn',title:'创建时间',type:'datetime',width:150,align:'left',sort:true},
                       {field:'UpdateBy',title:'更新人',type:'string',width:110,hidden:true,align:'left'},
                       {field:'LastUpdateOn',title:'更新时间',type:'datetime',width:150,hidden:true,align:'left',sort:true},
                       {field:'IsDeleted',title:'逻辑删除 0/不删除 1/已删除',type:'bool',width:110,hidden:true,align:'left'},
                       {field:'EQUTask_Id',title:'任务类型',type:'string',width:120,hidden:true,align:'left'},
                       {field:'OperationName',title:'工序',type:'string',width:120,hidden:true,align:'left'},
                       {field:'SHELVES_Id',title:'刀库点',type:'string',width:120,hidden:true,align:'left'},
                       {field:'ActionEquipmentId',title:'执行设备',type:'string',width:120,hidden:true,align:'left'},
                       {field:'ActionSubPathNo',title:'执行路径',type:'int',width:80,hidden:true,align:'left'},
                       {field:'ActionSort',title:'执行顺序',type:'int',width:80,hidden:true,align:'left'},
                       {field:'ProgramId',title:'程序',type:'string',width:120,hidden:true,align:'left'},
                       {field:'ExecuteTaskDiffTime',title:'执行时间',type:'int',width:80,hidden:true,align:'left'},
                       {field:'SecornSeq',title:'第二序',type:'int',width:80,hidden:true,align:'left'},
                       {field:'SendLog',title:'发送日志',type:'string',width:220,hidden:true,align:'left'},
                       {field:'AY',title:'A点Y值',type:'float',width:110,align:'left'},
                       {field:'BY',title:'B点Y值',type:'float',width:110,align:'left'},
                       {field:'ABInstance',title:'AB点差值',type:'float',width:110,align:'left'},
                       {field:'ARealityY',title:'A点校正Y值',type:'float',width:110,align:'left'},
                       {field:'BRealityY',title:'B点校正Y值',type:'float',width:110,align:'left'},
                       {field:'StepLocation',title:'推棒搭电停止位',type:'float',width:110,align:'left'},
                       {field:'FirstStopLocation',title:'第一次停止',type:'float',width:110,align:'left'},
                       {field:'AllinValue',title:'全推值',type:'float',width:110,align:'left'},
                       {field:'TwoDistance',title:'两次差值',type:'float',width:110,align:'left'},
                       {field:'NeedValue',title:'需要补偿值',type:'float',width:110,align:'left'},
                       {field:'NeedDistance',title:'补偿距离',type:'float',width:110,align:'left'},
                       {field:'BitVariable00',title:'BitVariable00',type:'float',width:110,hidden:true,align:'left'},
                       {field:'CNC_NUM',title:'设备No.',type:'int',width:80,align:'left'}]);
            const detail = ref({
                cnName: "#detailCnName",
                table: "#detailTable",
                columns: [],
                sortName: "",
                key: ""
            });
            return {
                table,
                extend,
                editFormFields,
                editFormOptions,
                searchFormFields,
                searchFormOptions,
                columns,
                detail,
            };
        },
    });
</script>
